<template>
	<view>
		<view class="category-wrap">
			<scroll-view class="category"
			 scroll-x="true" @scroll="scroll" scroll-left="120">
				<view class="c-wrap">
					
						<view @click="goList(value)" class="v"  v-for="value in data" :key="value.id" >
							<image class="img" :src="value.logo"></image>
							<text class="text">{{value.name}}</text>
						</view>
					
				</view>
			</scroll-view>
		</view>
	</view>
</template>

<script>
	
	
	export default {
		props:{
			data:{
				type:Array,
				default:()=>[]
			}
		},
		methods: {
			
			
			goList(value) {
				uni.navigateTo({
					url: '../list/list?type=' + value.type + '&id=' + value.id
				})
			},
			scroll() {

			}
		}
	}
</script>

<style lang="less" scoped>
	.category-wrap {
		padding: 15rpx 0;

	}


	.c-wrap {
		box-sizing: border-box;
		display: flex;
		align-items: center;
		// background-color: aqua;

	

			.v {
				display: block;
				width: 177.5upx;
				height: 180upx;
				padding: 24upx;
				line-height: 1;
				box-sizing: border-box;
				text-align: center;

				image {
					border-radius: 60upx;
					width: 120upx;
					height: 120upx;
				}

				.text {
					font-size: 28upx;
					color: #555555;
				}
			
		}
	}
</style>